package com.app.bean.vo;

import com.app.entity.Recommend;
import lombok.Data;

import java.io.Serializable;

/**
 * @autor xiaoyu.fang
 * @date 2019/10/10 13:37
 */
@Data
public class RecommendVO implements Serializable {
    /**
     * 标题
     */
    private String title;
    /**
     * 图片
     */
    private String image;

    public RecommendVO(){}

    public RecommendVO(String title, String image) {
        this.title = title;
        this.image = image;
    }

    public static RecommendVO getVO(Recommend recommend) {
        return new RecommendVO(recommend.getTitle(), recommend.getImage());
    }
}
